package com.effectiv.gooruda.domain;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

import org.joda.time.DateTime;
import org.springframework.data.annotation.CreatedBy;
import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.Id;
import org.springframework.data.annotation.LastModifiedBy;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.data.mongodb.core.mapping.DBRef;

@ToString
public class PersistentObject {
	
	@Getter @Setter
	@Id
	private String id;
	
	@DBRef
	@Getter @Setter
	private TenantCompany tenantCompany;
	
	
	@Getter @Setter
	@DBRef
	@CreatedBy
	private TenantCompanyUser createdBy;
	
	@DBRef
	@LastModifiedBy
	@Getter @Setter
	private TenantCompanyUser modifiedBy;

	@CreatedDate
	@Getter @Setter
	private DateTime createdDate;
	
	@LastModifiedDate
	@Getter @Setter
	private DateTime modifiedDate;
}
